This is a Rust implemention of Phi Accrual Failure Detector algorithm which is clearly described in the figure below. Using this algorithm you can detect remote server failure.